﻿<UserControl x:Class="Mengsk.ERP.App.Orders.OrderQuery.OrderQueryUserControl"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="1200" Loaded="UserControl_Loaded" Unloaded="UserControl_Unloaded" xmlns:my="clr-namespace:Mengsk.ERP.App.Orders">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>

        <TabControl Grid.Row="0" Name="tc">
            <TabItem Header="基础查询">
                <Grid >
                    <Grid.RowDefinitions>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                    </Grid.RowDefinitions>
                    
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="120"/>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="100"/>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="100"/>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="100"/>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="100"/>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="100"/>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="100"/>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="100"/>
                    </Grid.ColumnDefinitions>
                    
                    <TextBlock Grid.Row="0" Grid.Column="0" Text="QQ号码:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="0" Grid.Column="1" Name="tbID" Margin="3"/>
                    <TextBlock Grid.Row="0" Grid.Column="2" Text="真实姓名:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="0" Grid.Column="3" Name="tbRealName" VerticalAlignment="Center" Margin="3"/>
                    <TextBlock Grid.Row="0" Grid.Column="4" Text="物流单号:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="0" Grid.Column="5" Name="tbDeliveryNumber" Margin="3"/>
                    <TextBlock Grid.Row="0" Grid.Column="6" Text="手机号码:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="0" Grid.Column="7" Name="tbPhone" Margin="3" VerticalAlignment="Center"/>
                    <TextBlock Grid.Row="0" Grid.Column="8" Text="厂家货号:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="0" Grid.Column="9" Name="tbNumber" VerticalAlignment="Center" Margin="3"/>
                    <TextBlock Grid.Row="0" Grid.Column="10" Text="颜色:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="0" Grid.Column="11" Name="tbColor" Margin="3" VerticalAlignment="Center"/>
                    <TextBlock Grid.Row="0" Grid.Column="12" Text="尺码:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="0" Grid.Column="13" Name="tbSize" Margin="3" VerticalAlignment="Center"/>
                    <TextBlock Grid.Row="1" Text="开始时间：" Margin="3" VerticalAlignment="Center"/>
                    <DatePicker Grid.Row="1" Grid.Column="1" Name="dpStartTime" Margin="3" VerticalAlignment="Center"/>
                    <TextBlock Grid.Row="1" Grid.Column="2" Text="商品名称:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="1" Grid.Column="3" Grid.ColumnSpan="5" Name="tbProductName" Margin="3" VerticalAlignment="Center"/>
                    <TextBlock Grid.Row="1" Grid.Column="8" Text="收货地址:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="1" Grid.Column="9" Grid.ColumnSpan="5" Name="tbAddress" Margin="3"/>
                    <TextBlock Grid.Row="2" Grid.Column="0" Text="描述信息:" Margin="3" VerticalAlignment="Center"/>
                    <TextBox Grid.Row="2" Grid.Column="1" Grid.ColumnSpan="7" Name="tbComment" VerticalAlignment="Center"/>
                    <TextBlock Grid.Row="2" Grid.Column="8" Grid.ColumnSpan="10" Text="使用说明：收货地址与描述两样多关键查询，以空格分开。物流单号，手机号码，厂家货号，商品名称，地址都可以采用部分信息" Margin="3" VerticalAlignment="Center"/>
                </Grid>
            </TabItem>

            <TabItem Header="高级查询">
                <TextBox Name="tbSQLText" Height="100" HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto" AcceptsReturn="True" TextWrapping="Wrap" >
                </TextBox>
            </TabItem>
            <TabControl.SelectedIndex>0</TabControl.SelectedIndex>
        </TabControl>

        <Grid Grid.Row="1">
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="Auto"/>
                <ColumnDefinition Width="*"/>
                <ColumnDefinition Width="Auto"/>
            </Grid.ColumnDefinitions>
            <TextBlock Name="lbQueryResult" Grid.Column="0" Text="查询结果" Margin="3" VerticalAlignment="Center"/>
            <Button Name="btnQuery" Grid.Column="2" Content="查询" Margin="3" Width="80" Click="btnQuery_Click"/>
        </Grid>
        <my:OrderDetailUserControl Grid.Row="2"  x:Name="orderDetailUserControl1" />
    </Grid>
</UserControl>
